package cn.tedu.sample.controller;

import cn.tedu.sample.vo.JsonResult;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class DemoController {
    @GetMapping("/hello")
    public String demo() {
        return "Hello World!这是一个演示!";
    }

    @GetMapping("ajax")
    public JsonResult ajax() {
        return new JsonResult(1, "JSON返回值演示!");
    }
}
